org.eclipse.team.core.subscribers
Class ContentComparisonCriteria
java.lang.Object
org.eclipse.team.core.subscribers.ComparisonCriteria
org.eclipse.team.core.subscribers.ContentComparisonCriteria
- public class ContentComparisonCriteria
- extends ComparisonCriteria
A content comparison criteria that knows how to compare the content of IStorage
and
IRemoteResource
objects. The content comparison can be configured to ignore or
consider whitespace.
- See Also:
ComparisonCriteria
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
ID_IGNORE_WS
public static final String ID_IGNORE_WS
- See Also:
- Constant Field Values
ID_DONTIGNORE_WS
public static final String ID_DONTIGNORE_WS
- See Also:
- Constant Field Values
ContentComparisonCriteria
public ContentComparisonCriteria(ComparisonCriteria[] preConditions,
boolean ignoreWhitespace)
getName
public String getName()
- Description copied from class:
ComparisonCriteria
- Return the comparison criteria, in a format that is suitable for display to an end
user.
- Specified by:
getName
in class ComparisonCriteria
getId
public String getId()
- Description copied from class:
ComparisonCriteria
- Return the unique id that identified this comparison criteria.
- Specified by:
getId
in class ComparisonCriteria
compare
public boolean compare(Object e1,
Object e2,
IProgressMonitor monitor)
throws TeamException
- Helper methods for comparisons that returns true if the resource contents are the same.
If timestampDiff is true then the timestamps don't differ and there's no point checking the
contents.
- Specified by:
compare
in class ComparisonCriteria
- Parameters:
e1
- object to be comparede2
- object to be comparedmonitor
-
- Returns:
-
- Throws:
TeamException
shouldIgnoreWhitespace
protected boolean shouldIgnoreWhitespace()
usesFileContents
public boolean usesFileContents()
- Overrides:
usesFileContents
in class ComparisonCriteria
Copyright (c) IBM Corp. and others 2000, 2003. All Rights Reserved.